<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>关闭广告栏</title>
    <style type="text/css">
    	div{
        		width:120px;
        		height:271px;
        		margin:100px auto;
        		background: url(images/ad.png) no-repeat;
        	}
    </style>
    <script title="text/javascript">
        window.onload=function () {
            var B=document.getElementById("bj");
            var C=document.getElementById("gb");    //被关闭的盒子
            		C.onclick=function(){                      //鼠标点击事件
                         B.style.display="none";               //盒子被影藏
                	}
        }
    </script>
</head>
<body>
<div id="bj">
    <span id="gb">
 		<img src="images/close.jpg" alt="" />
 	</span>
</div>
</body>
</html>